box gadget: Implement cross-axis alignment
authorMatthias Clasen <mclasen@redhat.com>
Fri, 15 Jan 2016 11:47:31 +0000 (06:47 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Fri, 15 Jan 2016 14:43:12 +0000 (09:43 -0500)
commit87171469b7dba8ec8ae3397ed292b9d004ef5e90
tree1deecd79f665bfe318da3cdd274359f04a11c737
parent662c7b87e20aef1599faa994aebc65f4420838a8
box gadget: Implement cross-axis alignment

So far, the box gadget is always allocating all children the
full size in the cross axis. This behavior corresponds to the
align-items: stretch behavior in
https://www.w3.org/TR/css-flexbox-1/#align-items-property
This commit implements the other modes described there.

While widgets have halign/valign properties that we can use for
this, the API for inserting gadgets has to change to take an
extra align parameter. All callers have been updated to pass
GTK_ALIGN_FILL, since that corresponds to the previous behavior.

https://bugzilla.gnome.org/show_bug.cgi?id=760668
gtk/gtkboxgadget.c
gtk/gtkboxgadgetprivate.h
gtk/gtknotebook.c